<?php

/**
 * Game form.
 *
 * @package    edmuch
 * @subpackage form
 * @author     Your name here
 * @version    SVN: $Id: sfDoctrineFormTemplate.php 23810 2009-11-12 11:07:44Z Kris.Wallsmith $
 */
class GameForm extends BaseGameForm
{
  public function configure()
  {
      
   //   $this->widgetSchema['img'] = new sfWidgetFormInputFileEditable(array('file_src' => '/uploads/'.$this->getObject()->getImg(), 'edit_mode' => !$this->isNew(), 'with_delete' => true, 'is_image' => true));

 //$this->validatorSchema['img'] = new sfValidatorFile(array('required' => $this->getObject()->getImg()?false:true, 'mime_types' => 'web_images'), array('required' => 'Obrazek jest wymagany', 'mime_types' => 'Formaty: *.jpg, *.jpeg, *.gif, *.png'));
  
 
  $this->widgetSchema['img']        = new sfWidgetFormInputFile();
    $this->validatorSchema['img']     = new sfValidatorFile(array('path' => sfConfig::get('sf_upload_dir').'/games', 'required' => true));
 
 
  }
}
